import {useState} from 'react'
export default ()=>{
    const [count,setCount]=useState(0)
    return <div>
        <div>{count}</div>
        <button onClick={()=>{
            console.log('-1---------------');
            setCount(count=>count+2)
            console.log('-2---------------');
            setCount(count=>count+5)
            console.log('-3---------------');
            setCount(count=>count+8)
            console.log('-4---------------');
            setCount(count=>count+9)
            console.log('-5---------------');
            setCount(count=>count+10)
            console.log('-6---------------');
        }}>+</button>
    </div>
}